Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DAT 15505 Liquibase Extensions Parent POM #437

Merged
merged 52 commits into from
Oct 19, 2023
Merged

DAT 15505 Liquibase Extensions Parent POM #437

merged 52 commits into from
Oct 19, 2023

Conversation

jandroav
Copy link

jandroav added 9 commits September 12, 2023 14:17
…rvers

The Liquibase repositories and servers are added to the Maven settings in order to fetch dependencies from the Liquibase repositories. This allows the build and package process to include Liquibase dependencies when running the Maven command.
…vers sections for better readability and maintainability
…itories and servers

The maven settings XML file has been updated to include Liquibase repositories and servers. This allows the build and package process to access the Liquibase dependencies and artifacts. The repositories section now includes two repositories: "liquibase" and "liquibase-pro". The servers section also includes two servers: "liquibase-pro" and "liquibase". These changes ensure that the build process can fetch the required dependencies and artifacts from the Liquibase repositories using the provided credentials.
…mpatibility issue

chore(test.yml): update repositories and servers configuration to use multi-line format for better readability
…urations to maven settings

chore(test.yml): add liquibase-super-pom repository and server configurations to maven settings

chore(test.yml): add liquibase-super-pom repository and server configurations to maven settings
…allow using releases from the GitHub package registry
@vitaliimak
Copy link

Right now it doesn't work locally
image

@jandroav
Copy link
Author

Right now it doesn't work locally image

You need to configure your maven installation to get artifacts from GPM:

settings.xml
image

@vitaliimak
Copy link

Thank you @jandroav
Should all liquibase-mongodb contributors do the same? If so, could you please add an instruction to the README file?

@vitaliimak
Copy link

Doesn't work yet. Still trying to use only https://repo1.maven.org/maven2

<settings>
    <activeProfiles>
        <activeProfile>github</activeProfile>
    </activeProfiles>

    <profiles>
        <profile>
            <id>github</id>
            <repositories>
                <repository>
                    <id>centrlal</id>
                    <url>https://repo1.maven.org/maven2</url>
                </repository>
                <repository>
                    <id>liquibase</id>
                    <url>https://vitaliimak:[email protected]/liquibase/liquibase</url>
                    <snapshots>
                        <enabled>true</enabled>
                    </snapshots>
                </repository>
                <repository>
                    <id>liquibase-pro</id>
                    <url>https://vitaliimak:[email protected]/liquibase/liquibase-pro</url>
                    <snapshots>
                        <enabled>true</enabled>
                    </snapshots>
                </repository>
            </repositories>
        </profile>
    </profiles>
    <servers>
        <server>
            <id>github</id>
            <username>vitaliimak</username>
            <password>TOKEN</password>
        </server>
        <server>
            <id>liquibase</id>
            <username>vitaliimak</username>
            <password>TOKEN</password>
        </server>
    </servers>
 </settings>

image
image

@jandroav
Copy link
Author

jandroav commented Sep 13, 2023

Double check if you are configuring the correct settings.xml:

image
and remove the .m2\repository folder

@vitaliimak
Copy link

The configuration should be correct as other projects can use it successfully.

jandroav and others added 2 commits September 18, 2023 12:19
…o 'liquibase-parent-pom' and version from '0.0.1' to '0.1.0' for consistency and compatibility with the project
@jandroav jandroav changed the title DAT 15505 Liquibase Extensions Super POM DAT 15505 Liquibase Extensions Parent POM Sep 18, 2023
@jandroav
Copy link
Author

@vitaliimak updated the parent from to use the liquibase-parent-pom from Maven Central

jandroav added 2 commits September 18, 2023 12:32
…ter compatibility

feat(pom.xml): add JUnit Jupiter dependencies for unit testing
…poses

feat(pom.xml): add mockito-junit-jupiter dependency for testing purposes
@jandroav
Copy link
Author

@vitaliimak I also had to override the following plugins from the parent pom because latest versions are not compatible with the code from this extension:

        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-api</artifactId>
            <version>${jupiter.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-engine</artifactId>
            <version>${jupiter.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-params</artifactId>
            <version>${jupiter.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <version>${mockito-core.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-junit-jupiter</artifactId>
            <version>${mockito-junit-jupiter.version}</version>
            <scope>test</scope>
        </dependency>

build issues:

}
},
{
"id": "liquibase-super-pom",

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it the correct name? Is it "super"? For id and url.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah sorry, I deleted all references to it since it is not needed anymore

jandroav added 27 commits October 19, 2023 09:29
…b to ensure build job is completed before running tests
…lify workflow

chore(test.yml): remove unused Build Cache step to improve performance and reduce storage usage
…oth build and integration-tests jobs

feat(test.yml): add maven-settings-xml-action step to look for dependencies in maven repositories
feat(test.yml): add Build Cache step to cache build artifacts
chore(test.yml): update path for mongodb-test-results artifact in upload-artifact step
chore(pom.xml): remove unused dependencies and plugins
chore(pom.xml): remove profiles for remote repositories, coverage, and run-its
…nd configuration

feat(pom.xml): add liquibase-mongodb artifact as a dependency to the project for MongoDB support
… the project configuration

feat(pom.xml): update jackson-core version to 2.15.3 to ensure compatibility with other dependencies
…e project configuration

chore(pom.xml): remove distributionManagement section as it is not needed for this project
…tension version 0.5.0

chore(pom.xml): update Jupiter Surefire version to 1.3.2
chore(pom.xml): add Maven plugins for resources, compiler, gmavenplus, jar, build-helper, nexus-staging, shade, versions, release, and jacoco
chore(pom.xml): add distributionManagement configuration for Sonatype Nexus repositories
chore(pom.xml): add jacoco-maven-plugin to pluginManagement section and configure maven-surefire-plugin for unit and integration tests
…ng in test scope

The slf4j-api and slf4j-simple dependencies are added to the pom.xml file in the test scope. This is done to provide logging capabilities for tests.
…lity and functionality

feat(pom.xml): add dependencies for org.json and org.skyscreamer.jsonassert to support JSON testing
refactor(pom.xml): remove unused plugins and configurations for maven build and release
…ntegration Test job

chore(pom.xml): remove unused profiles from pom.xml file
…encies

The maven-surefire-plugin configuration and dependencies were removed from the pom.xml file. This plugin was previously used for running unit tests and integration tests. However, it is no longer needed in the project, so it was removed to simplify the build process and reduce unnecessary dependencies.
The hamcrest and assertj test dependencies were removed as they were not being used in the project. This cleanup improves the build process by reducing unnecessary dependencies.
The slf4j-api and slf4j-simple dependencies were removed from the pom.xml file as they were not being used in the project. This helps to reduce unnecessary dependencies and improve the overall cleanliness of the project.
…ng purposes

The slf4j-api and slf4j-simple dependencies are added to the pom.xml file. These dependencies are needed for testing purposes.
…n string to configure database connection parameters
…onnection URI with timeout settings

The integration test command in the test.yml file has been updated to include the MongoDB connection URI with timeout settings. This change ensures that the integration tests can connect to the MongoDB database with the specified timeout values.
… profile in the Maven command to run integration tests

feat(pom.xml): add 'run-its' profile to enable running integration tests with a specific MongoDB connection URI
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@jandroav jandroav merged commit 2ded8d0 into main Oct 19, 2023
19 checks passed
@jandroav jandroav deleted the DAT-15505 branch October 19, 2023 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants